package my.mybatis.common.request;


import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.ToString;
import my.mybatis.common.OrderParam;
import my.mybatis.common.QueryParam;

import java.io.Serializable;
import java.util.List;

@ToString
@ApiModel(description = "基础参数对象")
public class BaseRequestParam<T> implements Serializable{
    private static final long serialVersionUID = 4717631570911723144L;
    @ApiModelProperty(value = "当前页", required = true)
    private int pageNo;
    @ApiModelProperty(value = "每页的数量", required = true)
    private int pageSize = 10;
    @ApiModelProperty(value = "泛型参数对象", required = true)
    private T param;
    @ApiModelProperty(value = "排序字段", required = true)
    private List<OrderParam> orderParam;
    @ApiModelProperty(value = "特殊参数的封裝；eg：区间参数", required = true)
    private List<QueryParam> queryParam;

    public int getPageNo() {
        return pageNo;
    }

    public void setPageNo(int pageNo) {
        this.pageNo = pageNo;
    }

    public int getPageSize() {
        return pageSize;
    }

    public void setPageSize(int pageSize) {
        this.pageSize = pageSize;
    }

    public T getParam() {
        return param;
    }

    public void setParam(T param) {
        this.param = param;
    }

    public List<OrderParam> getOrderParam() {
        return orderParam;
    }

    public void setOrderParam(List<OrderParam> orderParam) {
        this.orderParam = orderParam;
    }

    public List<QueryParam> getQueryParam() {
        return queryParam;
    }

    public void setQueryParam(List<QueryParam> queryParam) {
        this.queryParam = queryParam;
    }
}
